package com.lanchetech.admin.service;


import com.lanchetech.bean.request.*;
import com.lanchetech.bean.response.BasePageResp;
import com.lanchetech.bean.response.BaseResp;
import com.lanchetech.bean.response.ResultData;
import com.lanchetech.bean.response.SpuResp;
import com.lanchetech.bean.vo.*;
import com.lanchetech.common.exception.ResultCodeException;
import com.lanchetech.entity.*;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;

public interface ProductService {

    ResultData<BasePageResp<SpuResp>> getSpuPage(SpuReq req);

    ResultData<BasePageResp<SpuResp>> getProductPage(SpuReq req);

    BaseResp editSpuAndSku(SpuEditVO spuEditVO);

    BaseResp editSpuSort(Spu req);

    ResultData<SpuEditVO> getSpuEditDetail(Long id);

    ResultData<BasePageResp<Spec>> getSpecPage(PageReq req);

    ResultData<List<Spec>> getSpecList();

    BaseResp editSpec(Spec spec);

    BaseResp deleteSpec(Long id);

    ResultData<BasePageResp<Unit>> getUnitPage(PageReq req);

    BaseResp editUnit(Unit unit);

    BaseResp deleteUnit(Long id);

    ResultData<List<Unit>> getUnitList();

    ResultData<BasePageResp<FreightTenantVO>> getFreightPage(PageReq req);

    BaseResp editFreight(FreightVO freightVO);

    ResultData<FreightVO> getFreightDetail(Long id);

    BaseResp deleteFreight(Long id);

    ResultData<List<Freight>> getFreightList(Long tenantId);

    BaseResp deleteProduct(Long id);

    ResultData<BasePageResp<SkuWithCommissionVO>> getSkuAndSkuCommissionPage(PageReq req);

    BaseResp editSkuCommission(SkuCommission req);

    BaseResp deleteSkuCommission(Long id);

    BaseResp editSpuCourierAmount(SpuCourierAmount req);

    ResultData<SpuCourierAmount> getSpuCourierAmount(Long spuId);

    BaseResp editZone(ZoneReq req);

    ResultData<BasePageResp<Zone>> getZonePage(ZonePageReq req);

    ResultData<ZoneVO> getZoneSpuDetail(Long zoneId);

    BaseResp deleteZone(Long zoneId);

    ResultData<BasePageResp<SelectionApplyVO>> getSelectionApplyPage(PageReq req);

    BaseResp auditSelectionApply(SelectionApply req);

    ResultData<SelectionApplyVO> getSelectionApplyDetail(Long id);

    BaseResp auditSelection(Selection req);

    ResultData<BasePageResp<Selection>> getSelectionPage(PageReq req);

    void exportSelectionExcel(PageReq req, HttpServletResponse response)  throws IOException;

    BaseResp batchOfflineProduct(BatchOfflineReq req);

    BaseResp resetSorts(Long startNum, Long endNum);

    BaseResp auditProduct(Long spuId, Byte type,String message);

    ResultData<List<SpuVO>> getTopSpu();

    ResultData<BasePageResp<BossRankingVo>> getBossRanking(PageReq req);

    BaseResp updateSpu(SpuEditVO spuEditVO) throws ResultCodeException;

    BaseResp preferredImage(Long spuId, boolean main);
}